﻿using System;
using Lua;
using MoonSharp.Interpreter;
using UnityEngine;

// Token: 0x020002A9 RID: 681
public class StepEvent : IEvent
{
	// Token: 0x06000F28 RID: 3880 RVA: 0x00073B8B File Offset: 0x00071D8B
	public StepEvent(EntityBase entity, UnityEngine.Vector3 position, float magnitude, int foot)
	{
		this.entity = entity;
		this.position = position;
		this.magnitude = magnitude;
		this.foot = foot;
		this.code = EventCode.OnStep;
	}

	// Token: 0x06000F29 RID: 3881 RVA: 0x00073BBC File Offset: 0x00071DBC
	public override DynValue GetLuaData()
	{
		if (this.data == null)
		{
			this.data = DynValue.NewPrimeTable();
			this.data.Table.Set("gts", DynValue.FromObject(null, this.entity.GetLuaEntity()));
			this.data.Table.Set("entity", DynValue.FromObject(null, this.entity.GetLuaEntity()));
			this.data.Table.Set("position", DynValue.FromObject(null, new Lua.Vector3(this.position)));
			this.data.Table.Set("magnitude", DynValue.FromObject(null, this.magnitude));
			this.data.Table.Set("foot", DynValue.FromObject(null, this.foot));
		}
		return this.data;
	}

	// Token: 0x0400141F RID: 5151
	public EntityBase entity;

	// Token: 0x04001420 RID: 5152
	public UnityEngine.Vector3 position;

	// Token: 0x04001421 RID: 5153
	public float magnitude;

	// Token: 0x04001422 RID: 5154
	public int foot;
}
